<template>
	<view class="content" :style="{backgroundImage:`url(${indexBackgroundImage})`}">
		
		<view class="main">
			<view class="icon" @tap="nextPage(`/pages/publishUniversity/publishUniversity?type=practice&index=3`)">
				<view class="item">
					<image src="/static/publish/practice.png" mode=""></image>
					<view class="itemName">
						<text>学生实践</text>
					</view>
				</view>
			</view>
			<view class="icon" @tap="nextPage(`/pages/publishUniversity/publishUniversity?type=practise&index=2`)">
				<view class="item">
					<image src="/static/publish/study.png" mode=""></image>
					<view class="itemName">
						<text>学生实习</text>
					</view>
				</view>
			</view>
			<view class="icon" @tap="nextPage(`/pages/publishUniversity/publishUniversity?type=school&index=1`)">
				<view class="item">
					<image src="/static/publish/university.png" mode=""></image>
					<view class="itemName">
						<text>校招</text>
					</view>
				</view>
			</view>
			<view class="icon" @tap="nextPage(`/pages/publishActive/publishActive`)">
				<view class="item">
					<image src="/static/publish/active.png" mode=""></image>
					<view class="itemName">
						<text>发布活动</text>
					</view>
				</view>
			</view>
			<view class="icon" @tap="nextPage(`/pages/publishCompany/publishCompany`)">
				<view class="item">
					<image src="/static/publish/company.png" mode=""></image>
					<view class="itemName">
						<text>企业风貌</text>
					</view>
				</view>
			</view>
			<view class="icon" v-if="0" @tap="nextPage(`/pages/publishEmploy/publishEmploy`)">
				<view class="item">
					<image src="/static/publish/employment.png" mode=""></image>
					<view class="itemName">
						<text>招聘介绍</text>
					</view>
				</view>
			</view>

		</view>
		<Tabbar :current="2"></Tabbar>
	</view>
</template>

<script>
	import indexBackgroundImage from "@/static/publish/bg1.png"
	export default {
		onShow() {
			uni.hideTabBar({
				animation: false
			})
		},
		data() {
			return {
				indexBackgroundImage: indexBackgroundImage
			};
		},
		methods: {
			//跳转列表对应页面
			nextPage(url) {
				uni.navigateTo({
					url: url,
					fail() {
						uni.switchTab({
							url: url,
							fail() {
								uni.showToast({
									title: '暂未开通，敬请期待！',
									icon: 'none'
								});
							}
						});
					}
				});
			}
		}
	}
</script>

<style lang="scss" scoped>
.content{
	background-repeat: no-repeat;
	background-size: 100%;
	height: 100vh;
	.title{
		width: 100%;
		height: 120rpx;
		line-height: 120rpx;
		text-align: center;
		text{
			font-size: 32rpx;
			letter-spacing: 5rpx;
			font-family: PingFang SC;
			font-weight: bold;
			color: #323233;
		}
	}
	.main{
		display: flex;
		flex-wrap: wrap;
		text-align: center;
		//padding-top: 10rpx;
		.icon{
			padding-top: 26rpx;
			flex-basis: 33.3%;
			.item{
				image{
					width: 130rpx;
					height: 130rpx;
				}
				.text{
					font-size: 28rpx;
					font-family: PingFang SC;
					font-weight: 500;
					color: #343434;
				}
			}
		}
	}
}
</style>
